<template>
  <div class="like">
    <div class="like-top">
      <img src="../../../assets/img/00.jpg">
      猜你喜欢
    </div>

    <ul>
      <li class="like-item border-bottom" 
      v-for="item in likeList"
      @click="toDetails"
      >
        <div class="like-img">
          <img :src="item.imgUrl">
        </div>

        <div class="like-text">
          <div class="like-title">{{item.title}}</div>
          <div class="like-message">{{item.msg}}条评论</div>
          <div class="like-map">
            <span class="like-mark">￥<b>{{item.pre}}</b></span>起
            <span class="like-mop">{{item.map}}</span>
          </div>
        </div>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  props:['likeList'],
    data(){
        return{
           
        }
    },
    methods:{
      toDetails(){
        this.$router.push('/detail')
      }
      
    }
};
</script>

<style scoped>
.like {
  margin-top: 0.2rem;
  font-size: 0.28rem;
  background: #fff;
  padding: 0.2rem;
}
.like-top {
  font-size: 0.32rem;
  padding: 0.1rem 0;
}
.like-top img {
  width: 0.3rem;
  height: 0.3rem;
}
.like-item {
  position: relative;
  padding: .2rem 0;
  overflow: hidden;
}
.like-img {
  float: left;
  overflow: hidden;
}
.like-img img {
  width: 2rem;
  height: 2rem;
}
.like-text {
  overflow: hidden;
  padding-left: 0.22rem;
}
.like-title {
  font-size: 0.36rem;
  color: #212121;
  margin-top: 0.4rem;
}
.like-message {
  margin-top: 0.3rem;
  font-size: 0.24rem;
  color: #7e7d7d;
}
.like-map {
    position: relative;
  margin-top: 0.3rem;
  color: #212121;
}
.like-mark{
    color: sandybrown;
}
.like-mark b{
    font-size: .4rem;

}
.like-mop{
    position: absolute;
    right: 0;
    top: .1rem;
    font-size: .28rem;
}
li{list-style-type:none}

</style>
